package JWT;

public class Identity {

    private String token; //token序列
    private String id; // 对应user的id
    private String issuer; //签发者
    private String role; // 角色
    private String userName; //用户名
    private Long duration; // 有效时长，单位毫秒

    public String getToken() {
        return token;
    }

    public void setToken(String token) {
        this.token = token;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getIssuer() {
        return issuer;
    }

    public void setIssuer(String issuer) {
        this.issuer = issuer;
    }

    public String getRole() {
        return role;
    }

    public void setRole(String role) {
        this.role = role;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public Long getDuration() {
        return duration;
    }

    public void setDuration(Long duration) {
        this.duration = duration;
    }

    @Override
    public String toString() {
        return "Identity{" +
                "token='" + token + '\'' +
                ", id='" + id + '\'' +
                ", issuer='" + issuer + '\'' +
                ", role='" + role + '\'' +
                ", userName='" + userName + '\'' +
                ", duration=" + duration +
                '}';
    }
}
